package com.yl.chainStore.services.warehouse

import com.baomidou.mybatisplus.extension.plugins.pagination.Page
import com.yl.chainStore.entity.warehouse.WarehouseInOrder
import com.yl.chainStore.entity.warehouse.WarehouseInOrderDetail
import com.yl.chainStore.pojo.vo.warehouse.WarehouseInOrderSelectVo
import com.yl.common.control.ResponseBody

/**
 * 入库订单管理
 */
interface IWarehouseInOrderService {

	/**
	 * 添加入库明细
	 */
	fun addDetail(detail: WarehouseInOrderDetail): ResponseBody

	/**
	 * 入库单
	 */
	fun getInOrder(id: Long): WarehouseInOrder?

	/**
	 * 入库明细
	 */
	fun inOrderDetails(orderId:Long):List<WarehouseInOrderDetail>

	/**
	 * 修改入库信息
	 */
	fun updateInOrder(inOrder: WarehouseInOrder): ResponseBody

	/**
	 * 修改入库明细
	 */
	fun updateInOrderDetail(detail: WarehouseInOrderDetail):ResponseBody

	/**
	 * 删除入库明细
	 */
	fun delInOrderDetail(detailId:Long):ResponseBody

	/**
	 * 完成入库
	 */
	fun completeInOrder(orderId: Long): ResponseBody

	/**
	 * 入库审核通过
	 */
	fun completeInOrder(inOrder: WarehouseInOrder): ResponseBody

	/**
	 * 入库审核作废
	 */
	fun noPassInOrder(id: Long):ResponseBody

	/**
	 * 取消入库（作废）
	 */
	fun cancelInOrder(id: Long): ResponseBody

	/**
	 * 删除入库单（物理删除，会把订单和订单详情都删除）
	 * 待处理之后的不能删除
	 */
	fun deleteInOrder(id:Long):ResponseBody
}